<?php
/***************************************************************
*  Copyright notice
*  (c) 2009, jianyuzhu@gmail.com
*  All rights reserved
*  This script is part of the PPEMI project.
***************************************************************/

class CoreWorkflow {
	var $_start = NULL;
	var $_end = NULL;
	var $_steps = NULL;
	var $_done = false;
	
	//constructor
	function CoreWorkflow() {
		$this->_steps = array();
	}
	
	//methods
	//process
	function start() {
		
	}
	
	function doing() {
		
	}
	
	function do_success() {
		
	}
	
	function do_fail() {
		
	}
	
	function do_result() {
		
	}
	
	//events
	function onEvent() {
		
	}
	
	function onSucess() {
		
	}
	
	function onFail() {
		
	}
	
	function onResult() {
		
	}
	
	//
	function addFirst($first) {
		$this->_first = $first;
	}
	
	function addStep($step) {
		$this->_steps[] = $step;
	}
	
	function addEnd($end) {
		$this->_end = $end;
	}
	
	//
	function isDone() {
		
	}
	
	//
	function getSteps() {
		return $this->_steps;
	}
}

//
class CoreWorkflowBase extends Base {
	
	//constructor
	function CoreWorkflowBase() {
		parent::Base();
	}
	
	//methods
}
//
?>